package com.hiultra.archive.service.impl;

import java.util.List;
import com.hiultra.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.hiultra.archive.mapper.ArcAppraialDetailsMapper;
import com.hiultra.archive.domain.ArcAppraialDetails;
import com.hiultra.archive.service.IArcAppraialDetailsService;

/**
 * 鉴定详情Service业务层处理
 * 
 * @author ls
 * @date 2023-08-31
 */
@Service
public class ArcAppraialDetailsServiceImpl implements IArcAppraialDetailsService 
{
    @Autowired
    private ArcAppraialDetailsMapper arcAppraialDetailsMapper;

    /**
     * 查询鉴定详情
     * 
     * @param appraisalDetailId 鉴定详情主键
     * @return 鉴定详情
     */
    @Override
    public ArcAppraialDetails selectArcAppraialDetailsByAppraisalDetailId(Long appraisalDetailId)
    {
        return arcAppraialDetailsMapper.selectArcAppraialDetailsByAppraisalDetailId(appraisalDetailId);
    }

    /**
     * 查询鉴定详情列表
     * 
     * @param arcAppraialDetails 鉴定详情
     * @return 鉴定详情
     */
    @Override
    public List<ArcAppraialDetails> selectArcAppraialDetailsList(ArcAppraialDetails arcAppraialDetails)
    {
        return arcAppraialDetailsMapper.selectArcAppraialDetailsList(arcAppraialDetails);
    }

    /**
     * 新增鉴定详情
     * 
     * @param arcAppraialDetails 鉴定详情
     * @return 结果
     */
    @Override
    public int insertArcAppraialDetails(ArcAppraialDetails arcAppraialDetails)
    {
        arcAppraialDetails.setCreateTime(DateUtils.getNowDate());
        return arcAppraialDetailsMapper.insertArcAppraialDetails(arcAppraialDetails);
    }

    /**
     * 修改鉴定详情
     * 
     * @param arcAppraialDetails 鉴定详情
     * @return 结果
     */
    @Override
    public int updateArcAppraialDetails(ArcAppraialDetails arcAppraialDetails)
    {
        arcAppraialDetails.setUpdateTime(DateUtils.getNowDate());
        return arcAppraialDetailsMapper.updateArcAppraialDetails(arcAppraialDetails);
    }

    /**
     * 批量删除鉴定详情
     * 
     * @param appraisalDetailIds 需要删除的鉴定详情主键
     * @return 结果
     */
    @Override
    public int deleteArcAppraialDetailsByAppraisalDetailIds(Long[] appraisalDetailIds)
    {
        return arcAppraialDetailsMapper.deleteArcAppraialDetailsByAppraisalDetailIds(appraisalDetailIds);
    }

    /**
     * 删除鉴定详情信息
     * 
     * @param appraisalDetailId 鉴定详情主键
     * @return 结果
     */
    @Override
    public int deleteArcAppraialDetailsByAppraisalDetailId(Long appraisalDetailId)
    {
        return arcAppraialDetailsMapper.deleteArcAppraialDetailsByAppraisalDetailId(appraisalDetailId);
    }
}
